home *** CD-ROM | disk | FTP | other *** search
/ Inter.Net 55-1 / Inter.Net 55-1.iso / CBuilder / Setup / BCB / data.z / setjmp.h < prev    next >
Encoding:
C/C++ Source or Header  |  1998-02-09  |  1.5 KB  |  83 lines

  1. /*  setjmp.h
  2.  
  3.     Defines typedef and functions for setjmp/longjmp.
  4.  
  5. */
  6.  
  7. /*
  8.  *      C/C++ Run Time Library - Version 9.0
  9.  *
  10.  *      Copyright (c) 1987, 1998 by Borland International
  11.  *      All Rights Reserved.
  12.  *
  13.  */
  14. /* $Revision:   9.3  $ */
  15.  
  16. #ifndef __SETJMP_H
  17. #define __SETJMP_H
  18. #define _INC_SETJMP  /* MSC Guard name */
  19.  
  20. #if !defined(___DEFS_H)
  21. #include <_defs.h>
  22. #endif
  23.  
  24. #ifdef __cplusplus
  25.   namespace std {
  26. #endif /* __cplusplus */
  27.  
  28. #ifdef __cplusplus
  29. extern "C" {
  30. #endif
  31.  
  32. #if !defined(RC_INVOKED)
  33.  
  34. #if defined(__STDC__)
  35. #pragma warn -nak
  36. #endif
  37.  
  38. #pragma pack(push, 1)
  39.  
  40. #endif  /* !RC_INVOKED */
  41.  
  42. typedef struct __jmp_buf {
  43.     unsigned    j_ebp;
  44.     unsigned    j_ebx;
  45.     unsigned    j_edi;
  46.     unsigned    j_esi;
  47.     unsigned    j_esp;
  48.     unsigned    j_ret;
  49.     unsigned    j_excep;
  50.     unsigned    j_context;
  51. }   jmp_buf[1];
  52.  
  53. void    _RTLENTRYF _EXPFUNC longjmp(jmp_buf __jmpb, int __retval);
  54. int     _RTLENTRYF _EXPFUNC setjmp(jmp_buf __jmpb);
  55.  
  56. #ifdef __cplusplus
  57. }
  58. #endif
  59.  
  60. #if !defined(RC_INVOKED)
  61.  
  62. /* restore default packing */
  63. #pragma pack(pop)
  64.  
  65. #if defined(__STDC__)
  66. #pragma warn .nak
  67. #endif
  68.  
  69. #endif  /* !RC_INVOKED */
  70.  
  71. #ifdef __cplusplus
  72. } // std
  73. #endif /* __cplusplus */
  74.  
  75. #endif  /* __SETJMP_H */
  76.  
  77. #if defined(__cplusplus) && !defined(__USING_CNAME__) && !defined(__SETJMP_H_USING_LIST)
  78. #define __SETJMP_H_USING_LIST
  79.      using std::jmp_buf;
  80.      using std::longjmp;
  81.      using std::setjmp;
  82. #endif /* __USING_CNAME__ */
  83.